﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Core.Model;
using FluentNHibernate.Automapping;
using FluentNHibernate.Automapping.Alterations;

namespace Core.DataAccess.Tools.Implementations.OverrideMappings
{
    public class AnswerMapping : IAutoMappingOverride<Core.Model.Answer>
    {
        #region Implementation of IAutoMappingOverride<Answer>

        public void Override(AutoMapping<Answer> mapping)
        {
            mapping.References(x => x.Question, "QuestionId").Cascade.None();
            mapping.References(x => x.User, "UserId").Cascade.None();
        }

        #endregion
    }
}
